// 把附件添加到组件中
export function setUploadFile(fileList) {
  return fileList.map(item => {
    return {
      fileName: item.fileName,
      fileId: item.fileId
    }
  }) || []
}

// 获取组件中的附件
export function getUploadFile(uploadRef) {
  const fileList = uploadRef ? uploadRef.fileList : []
  return fileList.map(item => {
    return {
      fileName: item.fileName,
      fileId: item.fileId
    }
  }) || []
}
